﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using BUS;
using System.Collections;

namespace PTTK11_HuongRung
{
    public partial class frmThucDon : Form
    {
        ThucDonBUS tdBUS;
        ArrayList dsThucDon;

        public frmThucDon()
        {
            InitializeComponent();
        }

        private void reLoadData()
        {
            dsThucDon = tdBUS.getDsThucDon();
            dgvDanhSach.DataSource = dsThucDon;
        }

        private void frmThucDon_Load(object sender, EventArgs e)
        {
            tdBUS = new ThucDonBUS();
            reLoadData();
        }

        private void btnTimKiem_Click(object sender, EventArgs e)
        {
            dsThucDon = tdBUS.TimKiem(dtpThoiGian.Value);
            dgvDanhSach.DataSource = dsThucDon;
        }
    }
}
